Class Iterator

Summary

Fully Qualified Name: CodeIgniter\Debug\Iterator

Description

Iterator for debugging.

Methods

Name Description Defined By
add() Adds a test to run. Iterator
getReport() Get results. Iterator
run() Runs through all of the tests that have been added, recording time to execute the desired number of iterations, and the approximate memory usage used during those iterations. Iterator

Method Details

add()

Adds a test to run.

Tests are simply closures that the user can define any sequence of things to happen during the test.

Parameter Name Type Description
$name string
$closure \Closure

Returns: $this

getReport()

Get results.

Returns: string

run()

Runs through all of the tests that have been added, recording time to execute the desired number of iterations, and the approximate memory usage used during those iterations.

Parameter Name Type Description
$iterations int
$output bool

Returns: string|null

Top